package com.ssm.service;

import com.ssm.pojo.Books;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * Created with IntelliJ IDEA.
 *
 * @Author: Cat.Sir
 * Description:
 * DateTime: 2022-04-28 22:59
 */
//BookService:底下需要去实现,调用dao层
public interface BookService {
    //增加一个Book
    int addBook(Books book);
    //根据id删除一个Book
    int deleteBookById(int id);
    //更新Book
    int updateBook(Books books);
    //根据id查询,返回一个Book
    Books queryBookById(int id);
    //查询全部Book,返回list集合
    List<Books> queryAllBook();
    //查询书籍通过名称
    Books queryBookByName(String bookName);
    //分页查询
    List<Books> queryBookByPage(int start,int end);
    //通过id查询书名
    String queryBookNameById(int id);
}
